'''
Created on Oct 19, 2009

@author: mkiyer
'''
import os

root = os.path.join(os.path.sep, 'lab', 'mkiyer', 'refdb')

def get_chrom_sizes(genome='hg18'):
    assert genome == 'hg18'
    return os.path.join(root, 'genomes', 'ucsc', 'hg18', 'hg18.chrom.sizes')

def get_hg18_illumina_sequences_path():
    return os.path.join(root, 'sequences', 'hg18_illumina')

def get_bowtie_indexes_path():
    return os.path.join(root, 'alignment', 'references', 'bowtie')

def get_tophat_sam_header_file():
    return os.path.join(root, 'tophat_config', 'tophat_sam_header.sam')

def get_custom_gtf(name):
    path = os.path.join(root, 'annotations', 'custom', name)
    return path if os.path.exists(path) else None

def get_ucsc_table(name, format):
    path = os.path.join(root, 'annotations', 'ucsc', '%s.%s' % (name, format))
    return path if os.path.exists(path) else None

def get_track(name):
    path = os.path.join(root, 'tracks', '%s.track' % (name))
    return path if os.path.exists(path) else None
